import React, { PureComponent } from 'react';
import { View, StyleSheet } from 'react-native';
import { adapt, isIPhoneX } from '~/utils/ScreenAdapter';

export default class IphoneXBottom extends PureComponent {
  constructor(props) {
    super(props);
  }

  componentDidMount() {}

  render() {
    const { style = {} } = this.props;

    if (isIPhoneX) {
      return <View style={[styles.iphoneXBottom, style]} />;
    }
    return null;
  }
}

const styles = StyleSheet.create({
  iphoneXBottom: {
    height: adapt(20),
    width: '100%',
  },
});
